package com.czxy.demo05;

import java.util.Random;

public class Test01 {

    public static void main(String[] args) {
        Random rd = new Random();
        int a = rd.nextInt(10000-1)+1;
        if (a >= 1 && a <= 9){
            System.out.println("000" + a);
        }else if (a >= 10 && a<=99){
            System.out.println("00"+a);
        }else if (a >= 100 && a <= 999){
            System.out.println("0"+a);
        }else if (a >= 1000 && a <= 9999){
            System.out.println(a);
        }
    }
}
